package wiki.douzi.helpyougrow.enumeration;

public enum ResponseCodeEnum {

    //系统通用
    SUCCESS(0,"成功"),
    INSERT_SUCCESS(0,"插入成功"),
    MODIFY_SUCCESS(0,"修改成功"),
    DELETE_SUCCESS(0,"删除成功"),
    //系统内部错误
    SELECT_NULL(1001, "数据未找到"),
    SYSTEM_ERROR(1002, "系统内部错误");

    private Integer code; //自定义消息码
    private String msg; //自定义消息体

    ResponseCodeEnum(Integer code,String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
